<template>
    <div id="recharge-success" class="bg-account">
        <div class="con-wrap bg-f success-top">
            <img src="/statics/home/images/icon-success.png" alt="success" class="pay-success"/>
            <p class="success-info">{{ detailInfo.pay_status_text }}</p>
        </div>
        <img src="/statics/home/images/hr-img.png" alt="hr" class="hr-img">
        <div class="con-wrap flex-nowrap bg-f success-bottom">
            <div class="success-left">
                <p>订单编号：</p>
                <p>创建时间：</p>
                <p>充值金额：</p>
                <p>付款方式：</p>
            </div>
            <div class="success-right">
                <p>{{ detailInfo.order_sn }}</p>
                <p>{{ detailInfo.created_at }}</p>
                <p>{{ detailInfo.money }}</p>
                <p>{{ detailInfo.pay_type_text }}</p>
            </div>
        </div>
        <a href="#/account/index" class="btn-1 btn-1-main">完成</a>
        <div class="btn-1 mt20" @click="back()">返回</div>
    </div>
</template>


<script>
export default {
    name: 'RechargeSuccess',
    data() {
        return {
            detail_id:0,
            detailInfo:{
                pay_type:1,
                order_sn:'',
                created_at:'',
                money:'',
                pay_type_text:'',
                pay_status_text:'',
            }
        }
    },
    created() { 
        this.detail_id = this.$route.params.id;
        this.$api.recharge.detail({detail_id:this.detail_id}).then(res => {
            this.detailInfo = res.result
        }).finally(e => {});
    },
    methods: {
        back(){
            this.$router.go(-1)
        },
    }
}
</script>
